package besta.moon.sql.expression;

import besta.moon.engine.table.Column;
import besta.moon.sql.Expression;

public class ColumnExpression extends Column {

    final private Expression expr;

    public ColumnExpression(Expression expr) {
        this.expr = expr;
    }

    @Override
    public String getName() {
        return expr.getAlias();
    }

    @Override
    public boolean isAutoIncrement() {
        return expr.isAutoIncrement();
    }

    @Override
    public boolean isCaseSensitive() {
        return expr.isCaseSensitive();
    }

    @Override
    public boolean isNullable() {
        return expr.isNullable();
    }

    @Override
    public int getDataType() {
        return expr.getDataType();
    }

    @Override
    public int getDisplaySize() {
        return expr.getDisplaySize();
    }

    @Override
    public int getScale() {
        return expr.getScale();
    }

    @Override
    public int getPrecision() {
        return expr.getPrecision();
    }

}
